<template>
	<view class="bigbox" v-if="status == 2">
		<view class="box">
			<swiper class="swiper" :indicator-dots="true"  @change="change">
				<swiper-item class="box1">
					<image src="../../static/24.png" mode=""></image>
				</swiper-item>
				<swiper-item class="box1">
					<image src="../../static/25.png" mode=""></image>
				</swiper-item>
				<swiper-item class="box1">
					<image src="../../static/26.png" mode=""></image>
				</swiper-item>
			</swiper>
			<button class="all_btn" v-if="s_index == 2" @click="login()">去登录</button>
		</view>
	</view>
</template>

<script>
	export default {
		data() {
			return {
				s_index:0,
				status:2
			};
		},
		onLoad:function() {
			console.log(uni.getStorageSync('yindao'))
			if(uni.getStorageSync('yindao') == 1){
				this.status = 1
				uni.navigateTo({
					url:'../login/login'
				})
			}
		},
		methods: {
			login:function(){
				uni.navigateTo({
					url:'../login/login'
				})
				uni.setStorageSync('yindao', 1);
			},
			change:function(e){
				this.s_index = e.detail.current
			}
		}
	};
</script>

<style>
	.box1>image{
		width: 100%;
		height: 538rpx;
	}
	.swiper{
		width: 627rpx;
		height: 814rpx;
	}
	.bigbox{
		height: 100vh;
		display: flex;
		justify-content: center;
		align-items: center;
	}
</style>
